
#include	"SysConfig.h"
#include	"Define.h"
#include	"Stdio.h"
#include	"Display.h"
#ifdef  ST7565P
#include	"ST7565P.h"
#endif
#ifdef  BLUETOOTH
#include	"Bluetooth.h"
#ifdef  MOVON
#include	"Movon.h"
#endif

#ifdef  MIC
#include	"MIC.h"
#endif

#ifdef  MOVON
extern MV_AV_STATUS ucMV_A2DP_Status;
#endif

extern unsigned char ucFUNC_FunctionSeq;
extern unsigned char ucDISP_Blink;

void BTA_DISP_IconMain(void)
{

}


void BTA_DISP_SubText(void)
{
	unsigned char ucBuf[3];

	memset(&ucBuf[0], 0x00, 3);
	memcpy(&ucBuf[0], "BT ", 3);	
#ifdef  ST7565P
	ST7565_UpdateSubDisplayData(&ucBuf[0]);
#endif

}

void BTA_DISP_Pause(void)
{
	unsigned char ucBuf[6];
	
	if  (ucDISP_Blink == 1)
	{
		return;
	}
	memcpy(&ucBuf[0], "PAUSE", 5);
	ucBuf[5] = 0x00;
	
#ifdef  ST7565P
	ST7565_UpdateDisplayString(14,&ucBuf[0], 0);
#endif

}

void BTA_DISP_Play(void)
{
	unsigned char ucBuf[8];
		
	memcpy(&ucBuf[0], "BT AUDIO", 8);
#ifdef  ST7565P		
	ST7565_UpdateDisplayData(7,ucBuf[0]);
	ST7565_UpdateDisplayData(16,ucBuf[1]);
	ST7565_UpdateDisplayData(30,ucBuf[3]);
	ST7565_UpdateDisplayData(41,ucBuf[4]);
	ST7565_UpdateDisplayData(50,ucBuf[5]);
	ST7565_UpdateDisplayData(59,ucBuf[6]);
	ST7565_UpdateDisplayData(62,ucBuf[7]);
#endif
}

void BTA_DISP_MainText(void)
{
	if	((ucFUNC_FunctionSeq == 0) && (ucMV_A2DP_Status != MV_A2DP_STREAMING))
	{
		BTA_DISP_Pause();
		return;
	}	
	
#ifdef  MIC
	if	(MIC_GetMicStatus() == MIC_ON)
	{
		MIC_DISP_MainText();
		return;
	}
#endif

	BTA_DISP_Play();
}

#endif
